package com.kuang.controller;

import com.kuang.service.AsyncService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class AsyncController {

    @Autowired
    AsyncService service;

    @RequestMapping("/hello")
    public String hello(){

        service.hello();//停止三秒,网站会转圈等待服务器响应
        return "OK";
    }
}
